﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage.Master" AutoEventWireup="true"
    CodeBehind="FA_Department.aspx.cs" Inherits="FixedAssets.Module.BasicInformation.FA_Department" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <span>部门信息</span>
    <script type="text/javascript">
        function ShowHidden(sid, ev) {
            ev = ev || window.event;
            var target = ev.target || ev.srcElement;
            var oDiv = document.getElementById("div" + sid);
            oDiv.style.display = oDiv.style.display == "none" ? "block" : "none";
            target.innerHTML = oDiv.style.display == "none" ? "显示" : "隐藏";
        }
  </script>
    <div>
       <%-- <wijmo:C1Menu ID="C1Menu1" runat="server" BackLinkText="后退" CrumbDefaultText="选择一个选项"
            OnItemClick="C1Menu1_ItemClick" TopLinkText="全部" AutoPostBack="True">
            <Animation Option="">
            </Animation>
            <ShowAnimation Option="">
            </ShowAnimation>
            <HideAnimation Option="">
                <Animated Effect="fade"></Animated>
            </HideAnimation>
            <Items>
                <wijmo:C1MenuItem runat="server" Text="添加子项" Value="ADDITEM" SkinID="sk4">
                </wijmo:C1MenuItem>
                <wijmo:C1MenuItem runat="server" Text="插入项目" Value="INSTERITEM" SkinID="sk5">
                </wijmo:C1MenuItem>
                <wijmo:C1MenuItem runat="server" Separator="True">
                </wijmo:C1MenuItem>
                <wijmo:C1MenuItem runat="server" Text="删除" Value="DELETEITEM" SkinID="sk6">
                </wijmo:C1MenuItem>
                <wijmo:C1MenuItem runat="server" Text="编辑" Value="EDITITEM" SkinID="sk7">
                </wijmo:C1MenuItem>
                <wijmo:C1MenuItem runat="server" Text="保存" Value="SAVE" SkinID="sk8">
                </wijmo:C1MenuItem>
            </Items>
        </wijmo:C1Menu>

        <wijmo:C1TreeView ID="C1TreeView1" runat="server" CssClass="wijmo-wijtree">
            <ExpandAnimation Option="">
            </ExpandAnimation>
            <CollapseAnimation Option="">
            </CollapseAnimation>
            <Nodes>
            </Nodes>
        </wijmo:C1TreeView>--%>
       <asp:GridView ID="MasterGridView" runat="server" AutoGenerateColumns="false"
      Width="780px" BorderWidth="1" OnRowDataBound="MasterGridView_RowDataBound"
      DataKeyNames="ParentId" ShowHeader="false">
      <Columns>
        <asp:TemplateField>
          <ItemTemplate>
            <div style="width: 100%; padding: 2px; font-weight: bold;
              background-color: #DEDEDE;float: left">
              <img src="../../images/down.gif" style="float: left" onclick="ShowHidden('<%#Eval("ParentId") %>',event)"><span style="float: left">单位名称：<%#Eval("SCORPNAME")%></span></div>
            <div style="background-color: #FFF; padding-left: 60px;
                clear: both" id="div<%#Eval("ParentId") %>">
              <asp:GridView ID="DetailGridView" runat="server"
                AutoGenerateColumns="False"
                HorizontalAlign="Left" DataKeyNames="SDEPARTMENTCODE"
                OnRowCommand="DetailGridView_RowCommand"
                 ShowHeader="false"
                OnRowDeleting="DetailGridView_RowDeleting" Width="720px">
                <HeaderStyle BackColor="#9999FF" />
                <Columns>
                  <asp:TemplateField HeaderText="部门名称" HeaderStyle-Width="540px">
                    <ItemTemplate>
                        <%#Eval("SDEPARTMENTNAME")%>
                    </ItemTemplate>
                      <HeaderStyle Width="540px" />
                  </asp:TemplateField>
                  
                 
                </Columns>
              </asp:GridView>
            </div>
          </ItemTemplate>
        </asp:TemplateField>
      </Columns>
    </asp:GridView>
    </div>
</asp:Content>
